home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / dskut / dogrevu.zip / DOGREVU.SCR next >
Text File  |  1991-03-18  |  8KB  |  142 lines

  1.                          Hard disk organization
  2.                                  with
  3.                              Disk OrGanizer
  4.  
  5.  
  6.     When I added a hard disk to my PC, I was wasn't concerned with the
  7. placement, on the disk, of the various programs that were accessed by
  8. CONFIG.SYS and AUTOEXEC.BAT. I knew from my floppy days that boot-up could
  9. be slow, indeed, if the drive had to seek far into the diskette for each
  10. program, but hard disks are SO fast (68 milliseconds -- practically
  11. instantaneous!) -- it didn't matter anymore.
  12.  
  13.     Soon, the disk was half full, and when I changed the boot-up stuff
  14. (always tinkering), the newer versions were far up on the disk. And I began
  15. to realize that there was a lot of thrashing going on! It was especially
  16. noticeable when loading large programs, which, I realized, were badly
  17. fragmented across the disk.
  18.  
  19.     Now, There are two important "asides" that should be brought up here --
  20. ways to help smooth out the hard disk, things that are useful in any case.
  21.  
  22. FASTOPEN
  23.  
  24.     FASTOPEN is part of DOS; I think it was new in release 3.3. It speeds
  25. thing up considerably by keeping an in-memory copy of the directories on the
  26. hard disk. So after reading a file from (say) the root segment, all or most
  27. of the root segment directory is kept in storage. So, next time AUTOEXEC
  28. goes after a file, DOS does not have to re-read the directory! Provides a
  29. very nice speedup; there is a dramatic drop in noise as AUTOEXEC loads
  30. FASTOPEN.
  31.  
  32. IBMCACHE
  33.  
  34.     IBMCACHE, part of DOS at 4.0, I think, retains hard disk data in storage.
  35. Much more than FASTOPEN: the latter keeps only directory information;
  36. IBMCACHE buffers everything read from the disk! Now, in order to do any
  37. good, you will need to have a large chunk of storage, say a few hundred
  38. kilobytes, so it isn't practical unless you have some expanded or extended
  39. memory available. I have 576K of my EMS (expanded) memory allocated to the
  40. disk cache. (Of course, I no longer use FASTOPEN.) There is another nicety:
  41. IBMCACHE is loaded from CONFIG.SYS, so the disk quiets down much sooner than
  42. it did with FASTOPEN.
  43.  
  44.     It's nice, too, that often-used utility programs need to load from the
  45. disk only once (or after long non-use), as, after the first time, it loads
  46. from cache memory. I used to put frequently-used programs on my RAM disk,
  47. but that's no longer necessary.
  48.  
  49. Back to the topic
  50.  
  51.     Of course, I knew from experience with floppies that my programs were
  52. stored in fragments, and I'd read enough PC magazines to have seen
  53. advertisements for disk de-fragmenting programs. They loudly proclaim how
  54. fast your disk will go! Then one of the mags did a comparison of about a
  55. dozen of them, giving very high marks to one called DOG, the Disk Organizer.
  56. Best of all, it was a shareware program! My cheap little heart leapt! Only
  57. $20!
  58.  
  59.     I found a version of DOG on JDR Electronic's bulletin board (408
  60. 559-0253), in the Hard Drive Utilities section; it's also on many others
  61. as DOG206.ZIP. Soon, I was reading its instructions. I practiced by
  62. operating on my RAM disk. I also tried some small files on a floppy.
  63.  
  64.     DOG permits you to specify the order in which files are to be placed on
  65. the disk. Files that are not explicitly placed are put following the
  66. explicit ones. In addition, you may place specific files at the TOP of your
  67. disk! This is useful if you have a few very large files (such as data bases)
  68. -- by putting them at the top, DOS doesn't have to seek past them looking for
  69. other files. Of course, if the files are being lengthened, it is less
  70. practical to put them high on the disk.
  71.  
  72.     All these file names are contained in a DOG control file called
  73. ORDER.DOG, in the root segment of the disk. In addition to the above, you
  74. may specify which directories are to be truncated; files that are not to be
  75. moved (usually involved with copy-crippled programs); and a couple options
  76. regarding presence of multi-processing and copy-protection.
  77.  
  78.     I listed first the things called from CONFIG and AUTOEXEC, then the
  79. sub-directories. After the [HIGH] command, I listed the database files that
  80. were to go at the top of the disk. Oh, yes, first of all were IBMBIO.COM and
  81. IBMDOS.COM!
  82.  
  83.     The first time, of course, the poor thing had to move hundreds of
  84. allocation units! But it's fast, and this took maybe 10 minutes. I noticed
  85. that it was running very smoothly, with little to-and-fro seeking. ARRRG! I
  86. had not disabled IBMCACHE!! I decided that the damage, if any, had already
  87. been done, so I waited. DOG completed its run, re-checked its results, and
  88. told me that there were zero fragmented files and one free area. OK so far.
  89. I ran FLUSH to purge the disk cache, then CHKDSK. All was well! (I rather
  90. suspect that FASTOPEN would have trouble, and would require a re-boot
  91. afterward.)
  92.  
  93.     DOG has another very important feature: it has five options as to the
  94. degree of rearranging to be done. You may specify a default in the ORDER
  95. file, and may override it when calling DOG. The options are:
  96.  
  97. PACK -- defragment all files, pack them down leaving no unallocated space
  98.     among them. Files stay in original order.
  99.  
  100. FILL -- defragment and move enough files to combine all unallocated space.
  101.     This is almost always faster than PACK, but the files will be out of
  102.     order, if that were to matter.
  103.  
  104. FAST -- do just enough rearranging to defragment all files. This option also
  105.     does a little FILLing, so it's a very good one to use often. It may
  106.     leave some free space among the files.
  107.  
  108. DIR -- defragment and arrange the (unspecified) files in the order that they
  109.     appear in the directory. I don't know just how this works for files in
  110.     various sub-directories.
  111.  
  112. DATE -- defragment and place oldest files first. This might reduce future
  113.     file movement by migrating changing files up nearer the free space.
  114.  
  115. IN EACH CASE, files that are explicitly placed will also be moved as
  116. necessary, and directories will be compressed. The program tests the
  117. directories and the FAT, produces a little report giving the number of files,
  118. fragments, and number of allocation units to be moved; then it asks whether
  119. to continue. Upon a "Y" reply, it does its work, giving only the number of
  120. allocation units already processed. It'd be nice if it gave the name of the
  121. file being worked on, but it doesn't. Lastly, it again tests the FAT, etc.,
  122. and gives the report again. You can see the results, remaining holes, if
  123. any. At any time during the process, you many hit ESC to tell it to stop.
  124. It will leave the disk in usable form, though it may be more fragmented than
  125. before, and you may need to use CHKDSK to free some unallocated space. I've
  126. never interrupted it, so I'm simply quoting the instructions here.
  127.  
  128.     In conclusion, DOG is a very flexible, convenient way to manage your hard
  129. disk. It permits explicit ordering of files and directories, and offers a
  130. choice of the degree of packing to be done. I run it nearly every time I've
  131. modified files on my disk. I sometimes use it on floppy disks, but it's
  132. really rather slow and noisy. I wish DOG had an option to bypass the
  133. de-fragmentation, so that on floppies, I could get just the explicit files
  134. and the directory packing. One can do this by explicitly listing all files
  135. to be left alone, but that's seldom practical, especially since DOG does not
  136. give the names of the fragmented files.
  137.  
  138. Clear Skies,
  139. Jim Van Nuland
  140. 1990 February 10
  141.  
  142.